

import { GetAction, PostAction } from './request'

export const Ajax = {
    getBanner: (data?: any) => GetAction('http://121.196.235.163:3000/banner', data),

    register: (data?: any) => PostAction('/api/register', data),

    login: (data?: any) => PostAction('/api/login', data),

    checkPhone: (data?: any) => PostAction('/api/chechphone', data),

    sendCaptcha: (data?: any) => PostAction('/api/sendcaptcha', data),
    // 校验验证码
    verifyCaptcha: (data?: any) => PostAction('/api/verifycaptcha', data),

    gettoken: (data?: any) => PostAction('/api/gettoken', data),

    changepass: (data?: any) => PostAction('/api/changepass', data),

    getuserinfo: (data?: any) => PostAction('/api/getuserinfo', data),

    uploadfile: (data?: any) => PostAction('/api/uploadfile', data),

    changeuserinfo: (data?: any) => PostAction('/api/changeuserinfo', data),

    getrolelist: (data?: any) => PostAction('/api/getrolelist', data),


    // 学科
    addxueke: (data?: any) => PostAction('/api/addxueke', data),

    getxuekelist: (data?: any) => PostAction('/api/getxuekelist', data),

    deletexueke: (data?: any) => PostAction('/api/deletexueke', data),

    updatexueke: (data?: any) => PostAction('/api/updatexueke', data),


    //  用户 
    adduser: (data?: any) => PostAction('/api/adduser', data),

    getallusers: (data?: any) => PostAction('/api/getallusers', data),

    deleteuser: (data?: any) => PostAction('/api/deleteuser', data),

    updateuser: (data?: any) => PostAction('/api/updateuser', data),


}